<!doctype html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<link href="css/mui.min.css" rel="stylesheet" />
	</head>

	<body>
		<div id="app">
			<input type="hidden" id="" />
			<header class="mui-bar mui-bar-nav">
				<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
				<h1 class="mui-title"></h1>
			</header>
			<div class="mui-content">
				<ul class="mui-table-view">
					
				</ul>
			</div>
		</div>

	</body>

</html>
<script src="js/mui.min.js"></script>
<script src="js/jquery.js"></script>
<script src="js/vue.js"></script>
<script type="text/javascript">
	mui.init();
	mui.plusReady(function() {
		plus.webview.currentWebview().setStyle({
			scrollIndicator: 'none'
		});
	});
	var app = new Vue({
		el: '#app',
		mounted:function(){
			this.val = qu('VAL');
		},
		data: {
			val:'',//搜索关键字
		}
	});
	var style= qu('KEY');
	var comName=qu('comName');
	
	var comId="";
	var data={};
	if(style){
		data={style:style}
	}else{
		data={comName:comName}
	}
	console.log(JSON.stringify( data ))
	$(function(){
		mui.ajax(URL+'meCompanyUser!findComByStyle',{
		data:data,
		dataType:'json',//服务器返回json格式数据
		type:'post',//HTTP请求类型
		//timeout:10000,//超时时间设置为10秒；
		success:function(data){
		console.log(JSON.stringify( data ));
			var result= data.clazz;
			if(result!=null&&result.length>0){
				for(var i=0;i<result.length;i++){
					$("ul").append('<li id="'+result[i].id+'" class="mui-table-view-cell" >'
					+'			<a href="javascript:;" class="mui-navigate-right">'
					+'				<img class="mui-media-object mui-pull-left" src="images/bangong.jpg">'
					+'				<div class="mui-media-body mui-ellipsis">'
					+                 result[i].comName
					+'					<p class="mui-ellipsis">'+result[i].comAddress+' </p>'
					+'				</div>'
					+'			</a>'
					+'		</li>'
					);
				}
				
				
			}else{
				$("ul").append("<h3 style='line-height: 40px;text-align: center;'>无<h3>")
			}
			
		},
		error:function(xhr,type,errorThrown){
			console.log(JSON.stringify(xhr), type);
			
		}
	});
	
	mui(".mui-table-view").on('tap', '.mui-table-view-cell', function() {
		
		cun('comId', this.id);
		cun('KEY',style);
		tiao('detail');
	})
	})
	
	
</script>